package com.bungarus.model;

public class Device {
    private String id;
    private String mid;
    private String tenantId;
    private Type type;
    private String app;
    private String name;
    private Status status;

    public static class Builder{
        private Device device;
        private Builder() {
            this.device = new Device();
        }

        public static Builder newBuilder() {
            return new Builder();
        }

        public Builder id(String id) {
            this.device.setId(id);
            return this;
        }

        public Builder user(String uid) {
            this.device.setMid(uid);
            return this;
        }

        public Builder tenant(String tenantId) {
            this.device.setTenantId(tenantId);
            return this;
        }

        public Builder type(Type type) {
            this.device.setType(type);
            return this;
        }

        public Builder app(String app) {
            this.device.setApp(app);
            return this;
        }

        public Builder name(String name) {
            this.device.setName(name);
            return this;
        }

        public Builder status(Status status) {
            this.device.setStatus(status);
            return this;
        }

        public Device build() {
            return this.device;
        }
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getMid() {
        return mid;
    }

    public void setMid(String mid) {
        this.mid = mid;
    }

    public String getTenantId() {
        return tenantId;
    }

    public void setTenantId(String tenantId) {
        this.tenantId = tenantId;
    }

    public Type getType() {
        return type;
    }

    public void setType(Type type) {
        this.type = type;
    }

    public String getApp() {
        return app;
    }

    public void setApp(String app) {
        this.app = app;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Status getStatus() {
        return status;
    }

    public void setStatus(Status status) {
        this.status = status;
    }

    public enum Status{
        NEW,
        VALID,
        INVALID;
    }

    public enum Type {
        MOBILE_PHONE,
        MOBILE_PAD,
        PC;
    }
}
